home *** CD-ROM | disk | FTP | other *** search
/ Explorers of the New World / Explorers of the New World.iso / pc / exhelp.dir / 00040_PRINT.ls < prev    next >
Encoding:
Text File  |  1995-09-06  |  922 b   |  32 lines

  1. on printText
  2.   global printButton, browserTopicsLine, textSprite
  3.   activateButtonThenEnable(printButton)
  4.   set textCastName to the name of cast the castNum of sprite textSprite
  5.   set whichTopic to word 1 to the number of words in textCastName - 1 of textCastName
  6.   printTopic(whichTopic)
  7. end
  8.  
  9. on printTopic whichTopic
  10.   set theText to getAllTextInTopic(whichTopic)
  11.   if the machineType = 256 then
  12.     printTextFromPC(theText)
  13.   else
  14.     printTextFromMac(theText)
  15.   end if
  16. end
  17.  
  18. on getAllTextInTopic whichTopic
  19.   global currentPage
  20.   set theText to the text of field (whichTopic && "TEXT" & 1)
  21.   set oldCurrentPage to currentPage
  22.   resetCurrentPage()
  23.   set nextPageCast to getNextPageCast(1)
  24.   repeat while nextPageCast <> -1
  25.     set theText to theText && the text of cast nextPageCast
  26.     updateCurrentPage(1)
  27.     set nextPageCast to getNextPageCast(1)
  28.   end repeat
  29.   set currentPage to oldCurrentPage
  30.   return theText
  31. end
  32.